import { Entity, Column, PrimaryGeneratedColumn, CreateDateColumn, UpdateDateColumn } from 'typeorm';

@Entity()
export class UserBase {

  @PrimaryGeneratedColumn('uuid', { comment: '用户ID' })
  uid: string;

  @Column({ type: 'varchar', length: 32, comment: '用户名', })
  name: string;

  @Column({ type: 'varchar', length: 50, comment: '密码' })
  password: string;

  @Column({ type: 'tinyint', comment: '性别' })
  gender: number;

  @Column({ type: 'varchar', length: 100, comment: '邮箱' })
  email: string;

  @Column({ type: 'varchar', length: 11, comment: '手机号' })
  mobile: string;

  @CreateDateColumn({ type: 'timestamp', comment: '创建时间' })
  create_time: Date;

  @UpdateDateColumn({ type: 'timestamp', comment: '更新时间' })
  update_time: Date;
}